#include <iostream>
#include <vector>
#include <algorithm>
#include <queue>
using namespace std;

//字符流中第一个不重复的字符
int hashmap[256];
queue<char> q;

Solution()
{
    memset(hashmap, 0, sizeof(hashmap));
}

void Insert(char ch)
{
    hashmap[ch]++;
    if (hashmap[ch] <= 1)
    {
        q.push(ch);
    }
}

char FirstAppearingOnce()
{
    while (!q.empty() && hashmap[q.front()] > 1)
    {
        q.pop();
    }
    return q.empty() ? '#' : q.front();
}

void test()
{
}

int main()
{
    test();
    return 0;
}